package com.sq.universe.system.dao;

import com.sq.universe.base.ann.DataPermissionAnn;
import com.sq.universe.base.dao.BaseDao;
import com.sq.universe.system.entity.AutoCodeEntity;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Repository
public interface AutoCodeDao extends BaseDao<AutoCodeEntity> {

    /**
     * 查询所有的表
     * @return
     */
    @DataPermissionAnn
    public List<Map> getTables();

    /**
     * 查询单表属性
     * @param tableName
     * @return
     */
    public List<AutoCodeEntity> queryTableDetail(@Param("tableName") String tableName);

    /**
     * 查看表属性详情
     * @param tableName
     * @return
     */
    public Map tableFieldDetail(@Param("tableName") String tableName);
}
